package com.zhang.log4j2Bug;



import javax.naming.Reference;
import java.rmi.registry.LocateRegistry;
import java.rmi.registry.Registry;

/**
 * @Author: zhangxuzhuang
 * @DateTime: 2021/12/23 12:09
 * @Description: TODO
 */
public class RMIServer {
//    public static void main(String[] args) {
//        try {
//            LocateRegistry.createRegistry(1099);
//            Registry registry = LocateRegistry.getRegistry();
//            Reference reference = new Reference("com.zhang.designmode.Demo",
//                    "com.zhang.designmode.Demo", null);
//            ReferenceWrapper referenceWrapper = new ReferenceWrapper(reference);
//
//            registry.bind("Demo", referenceWrapper);
//
//        } catch (Exception e) {
//            e.printStackTrace();
//        }
//    }
}
